Integrand size = 25, antiderivative size = 156 \[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\frac {b \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {n p}{2},\frac {1}{2} (2-n p),\cos ^2(e+f x)\right ) \left (c (d \sec (e+f x))^p\right )^n \sin (e+f x)}{f n p \sqrt {\sin ^2(e+f x)}}-\frac {a \cos (e+f x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (1-n p),\frac {1}{2} (3-n p),\cos ^2(e+f x)\right ) \left (c (d \sec (e+f x))^p\right )^n \sin (e+f x)}{f (1-n p) \sqrt {\sin ^2(e+f x)}} \]
b*hypergeom([1/2, -1/2*n*p],[-1/2*n*p+1],cos(f*x+e)^2)*(c*(d*sec(f*x+e))^p )^n*sin(f*x+e)/f/n/p/(sin(f*x+e)^2)^(1/2)-a*cos(f*x+e)*hypergeom([1/2, -1/ 2*n*p+1/2],[-1/2*n*p+3/2],cos(f*x+e)^2)*(c*(d*sec(f*x+e))^p)^n*sin(f*x+e)/ f/(-n*p+1)/(sin(f*x+e)^2)^(1/2)
Time = 0.18 (sec) , antiderivative size = 125, normalized size of antiderivative = 0.80 \[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\frac {\csc (e+f x) \left (a (1+n p) \cos (e+f x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {n p}{2},1+\frac {n p}{2},\sec ^2(e+f x)\right )+b n p \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (1+n p),\frac {1}{2} (3+n p),\sec ^2(e+f x)\right )\right ) \left (c (d \sec (e+f x))^p\right )^n \sqrt {-\tan ^2(e+f x)}}{f n p (1+n p)} \]
(Csc[e + f*x]*(a*(1 + n*p)*Cos[e + f*x]*Hypergeometric2F1[1/2, (n*p)/2, 1 + (n*p)/2, Sec[e + f*x]^2] + b*n*p*Hypergeometric2F1[1/2, (1 + n*p)/2, (3 + n*p)/2, Sec[e + f*x]^2])*(c*(d*Sec[e + f*x])^p)^n*Sqrt[-Tan[e + f*x]^2]) /(f*n*p*(1 + n*p))
Time = 0.59 (sec) , antiderivative size = 177, normalized size of antiderivative = 1.13, number of steps used = 8, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.320, Rules used = {3042, 4436, 3042, 4274, 3042, 4259, 3042, 3122}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int (a+b \sec (e+f x)) \left (c (d \sec (e+f x))^p\right )^n \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int (a+b \sec (e+f x)) \left (c (d \sec (e+f x))^p\right )^ndx\) |
\(\Big \downarrow \) 4436 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \int (d \sec (e+f x))^{n p} (a+b \sec (e+f x))dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \int \left (d \csc \left (e+f x+\frac {\pi }{2}\right )\right )^{n p} \left (a+b \csc \left (e+f x+\frac {\pi }{2}\right )\right )dx\) |
\(\Big \downarrow \) 4274 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \left (a \int (d \sec (e+f x))^{n p}dx+\frac {b \int (d \sec (e+f x))^{n p+1}dx}{d}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \left (a \int \left (d \csc \left (e+f x+\frac {\pi }{2}\right )\right )^{n p}dx+\frac {b \int \left (d \csc \left (e+f x+\frac {\pi }{2}\right )\right )^{n p+1}dx}{d}\right )\) |
\(\Big \downarrow \) 4259 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \left (a \left (\frac {\cos (e+f x)}{d}\right )^{n p} (d \sec (e+f x))^{n p} \int \left (\frac {\cos (e+f x)}{d}\right )^{-n p}dx+\frac {b \left (\frac {\cos (e+f x)}{d}\right )^{n p} (d \sec (e+f x))^{n p} \int \left (\frac {\cos (e+f x)}{d}\right )^{-n p-1}dx}{d}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \left (a \left (\frac {\cos (e+f x)}{d}\right )^{n p} (d \sec (e+f x))^{n p} \int \left (\frac {\sin \left (e+f x+\frac {\pi }{2}\right )}{d}\right )^{-n p}dx+\frac {b \left (\frac {\cos (e+f x)}{d}\right )^{n p} (d \sec (e+f x))^{n p} \int \left (\frac {\sin \left (e+f x+\frac {\pi }{2}\right )}{d}\right )^{-n p-1}dx}{d}\right )\) |
\(\Big \downarrow \) 3122 |
\(\displaystyle (d \sec (e+f x))^{-n p} \left (c (d \sec (e+f x))^p\right )^n \left (\frac {b \sin (e+f x) (d \sec (e+f x))^{n p} \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {n p}{2},\frac {1}{2} (2-n p),\cos ^2(e+f x)\right )}{f n p \sqrt {\sin ^2(e+f x)}}-\frac {a d \sin (e+f x) (d \sec (e+f x))^{n p-1} \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (1-n p),\frac {1}{2} (3-n p),\cos ^2(e+f x)\right )}{f (1-n p) \sqrt {\sin ^2(e+f x)}}\right )\) |
((c*(d*Sec[e + f*x])^p)^n*((b*Hypergeometric2F1[1/2, -1/2*(n*p), (2 - n*p) /2, Cos[e + f*x]^2]*(d*Sec[e + f*x])^(n*p)*Sin[e + f*x])/(f*n*p*Sqrt[Sin[e + f*x]^2]) - (a*d*Hypergeometric2F1[1/2, (1 - n*p)/2, (3 - n*p)/2, Cos[e + f*x]^2]*(d*Sec[e + f*x])^(-1 + n*p)*Sin[e + f*x])/(f*(1 - n*p)*Sqrt[Sin[ e + f*x]^2])))/(d*Sec[e + f*x])^(n*p)
3.3.39.3.1 Defintions of rubi rules used
Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[Cos[c + d*x]*(( b*Sin[c + d*x])^(n + 1)/(b*d*(n + 1)*Sqrt[Cos[c + d*x]^2]))*Hypergeometric2 F1[1/2, (n + 1)/2, (n + 3)/2, Sin[c + d*x]^2], x] /; FreeQ[{b, c, d, n}, x] && !IntegerQ[2*n]
Int[(csc[(c_.) + (d_.)*(x_)]*(b_.))^(n_), x_Symbol] :> Simp[(b*Csc[c + d*x] )^(n - 1)*((Sin[c + d*x]/b)^(n - 1) Int[1/(Sin[c + d*x]/b)^n, x]), x] /; FreeQ[{b, c, d, n}, x] && !IntegerQ[n]
Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)), x_Symbol] :> Simp[a Int[(d*Csc[e + f*x])^n, x], x] + Simp[b/d In t[(d*Csc[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, n}, x]
Int[((c_.)*((d_.)*sec[(e_.) + (f_.)*(x_)])^(p_))^(n_)*((a_.) + (b_.)*sec[(e _.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Simp[c^IntPart[n]*((c*(d*Sec[e + f*x ])^p)^FracPart[n]/(d*Sec[e + f*x])^(p*FracPart[n])) Int[(a + b*Sec[e + f* x])^m*(d*Sec[e + f*x])^(n*p), x], x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && !IntegerQ[n]
\[\int \left (c \left (d \sec \left (f x +e \right )\right )^{p}\right )^{n} \left (a +b \sec \left (f x +e \right )\right )d x\]
\[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\int { {\left (b \sec \left (f x + e\right ) + a\right )} \left (\left (d \sec \left (f x + e\right )\right )^{p} c\right )^{n} \,d x } \]
\[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\int \left (c \left (d \sec {\left (e + f x \right )}\right )^{p}\right )^{n} \left (a + b \sec {\left (e + f x \right )}\right )\, dx \]
\[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\int { {\left (b \sec \left (f x + e\right ) + a\right )} \left (\left (d \sec \left (f x + e\right )\right )^{p} c\right )^{n} \,d x } \]
\[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\int { {\left (b \sec \left (f x + e\right ) + a\right )} \left (\left (d \sec \left (f x + e\right )\right )^{p} c\right )^{n} \,d x } \]
Timed out. \[ \int \left (c (d \sec (e+f x))^p\right )^n (a+b \sec (e+f x)) \, dx=\int {\left (c\,{\left (\frac {d}{\cos \left (e+f\,x\right )}\right )}^p\right )}^n\,\left (a+\frac {b}{\cos \left (e+f\,x\right )}\right ) \,d x \]